package com.jdyfy.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.List;

import static com.baomidou.mybatisplus.annotation.IdType.AUTO;

@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@TableName("menus") //数据库中对应的表名
public class Menu implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(type =  AUTO)
    private Long menuId;

    private String menuName;

    private String menuUrl;

    private String menuIcon;

    private String menuDescription;

    @TableField(exist = false)
    private List<Menu> children;

    private Long pid;

    private String pagePath;
}
